{% extends 'layout.html' %}
{% block maincontent%}
    <h2 class='text-center'> 编辑诗歌 </h2>
    <form action="{% url 'poem:svc_edit' poem.id %}" method="post">
        <!-- django中防止csrf攻击的方式 -->
        {% csrf_token %}

        <div class='form-group'>
            <input class='form-control' type="text" name="title" value="{{poem.title}}">
        </div>
        <div class='form-group'>
            <input class='form-control' type="text" name="content" value="{{poem.content}}">
        </div>
        <div class='form-group'>
            <input class='btn btn-primary' type="submit" value='修改诗歌'>
        </div>
    </form>
{% endblock %}